package db;

import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;

/**
 * Created by ZuoShu on 16/12/2.
 */
@Entity
@Table(name = "RoomInfo", schema = "", catalog = "")
public class RoomInfoEntity {
    private Integer roomGuid;
    private Integer firstTableGuid;
    private Integer endTableGuid;
    private String roomValue;
    private String roomPutScroe;
    private String factor;
    private String level;
    private String cannonCost;
    private String cannonCount;
    private String speedfrequency;
    private int low;
    private int mid;
    private int high;
    private String fishBonus;
    private String clientspeedfrequency;

    @Basic
    @Column(name = "RoomGUID", nullable = true)
    public Integer getRoomGuid() {
        return roomGuid;
    }

    public void setRoomGuid(Integer roomGuid) {
        this.roomGuid = roomGuid;
    }

    @Basic
    @Column(name = "FirstTableGUID", nullable = true)
    public Integer getFirstTableGuid() {
        return firstTableGuid;
    }

    public void setFirstTableGuid(Integer firstTableGuid) {
        this.firstTableGuid = firstTableGuid;
    }

    @Basic
    @Column(name = "EndTableGUID", nullable = true)
    public Integer getEndTableGuid() {
        return endTableGuid;
    }

    public void setEndTableGuid(Integer endTableGuid) {
        this.endTableGuid = endTableGuid;
    }

    @Basic
    @Column(name = "RoomValue", nullable = true, length = 0)
    public String getRoomValue() {
        return roomValue;
    }

    public void setRoomValue(String roomValue) {
        this.roomValue = roomValue;
    }

    @Basic
    @Column(name = "RoomPutScroe", nullable = true, length = 0)
    public String getRoomPutScroe() {
        return roomPutScroe;
    }

    public void setRoomPutScroe(String roomPutScroe) {
        this.roomPutScroe = roomPutScroe;
    }

    @Basic
    @Column(name = "factor", nullable = true, length = 0)
    public String getFactor() {
        return factor;
    }

    public void setFactor(String factor) {
        this.factor = factor;
    }

    @Basic
    @Column(name = "level", nullable = true, length = 0)
    public String getLevel() {
        return level;
    }

    public void setLevel(String level) {
        this.level = level;
    }

    @Basic
    @Column(name = "CannonCost", nullable = true, length = 0)
    public String getCannonCost() {
        return cannonCost;
    }

    public void setCannonCost(String cannonCost) {
        this.cannonCost = cannonCost;
    }

    @Basic
    @Column(name = "CannonCount", nullable = true, length = 0)
    public String getCannonCount() {
        return cannonCount;
    }

    public void setCannonCount(String cannonCount) {
        this.cannonCount = cannonCount;
    }

    @Basic
    @Column(name = "speedfrequency", nullable = false, length = 0)
    public String getSpeedfrequency() {
        return speedfrequency;
    }

    public void setSpeedfrequency(String speedfrequency) {
        this.speedfrequency = speedfrequency;
    }

    @Basic
    @Column(name = "low", nullable = false)
    public int getLow() {
        return low;
    }

    public void setLow(int low) {
        this.low = low;
    }

    @Basic
    @Column(name = "mid", nullable = false)
    public int getMid() {
        return mid;
    }

    public void setMid(int mid) {
        this.mid = mid;
    }

    @Basic
    @Column(name = "high", nullable = false)
    public int getHigh() {
        return high;
    }

    public void setHigh(int high) {
        this.high = high;
    }

    @Basic
    @Column(name = "fishBonus", nullable = false, length = 0)
    public String getFishBonus() {
        return fishBonus;
    }

    public void setFishBonus(String fishBonus) {
        this.fishBonus = fishBonus;
    }

    @Basic
    @Column(name = "clientspeedfrequency", nullable = false, length = 0)
    public String getClientspeedfrequency() {
        return clientspeedfrequency;
    }

    public void setClientspeedfrequency(String clientspeedfrequency) {
        this.clientspeedfrequency = clientspeedfrequency;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        RoomInfoEntity that = (RoomInfoEntity) o;

        if (low != that.low) return false;
        if (mid != that.mid) return false;
        if (high != that.high) return false;
        if (roomGuid != null ? !roomGuid.equals(that.roomGuid) : that.roomGuid != null) return false;
        if (firstTableGuid != null ? !firstTableGuid.equals(that.firstTableGuid) : that.firstTableGuid != null)
            return false;
        if (endTableGuid != null ? !endTableGuid.equals(that.endTableGuid) : that.endTableGuid != null) return false;
        if (roomValue != null ? !roomValue.equals(that.roomValue) : that.roomValue != null) return false;
        if (roomPutScroe != null ? !roomPutScroe.equals(that.roomPutScroe) : that.roomPutScroe != null) return false;
        if (factor != null ? !factor.equals(that.factor) : that.factor != null) return false;
        if (level != null ? !level.equals(that.level) : that.level != null) return false;
        if (cannonCost != null ? !cannonCost.equals(that.cannonCost) : that.cannonCost != null) return false;
        if (cannonCount != null ? !cannonCount.equals(that.cannonCount) : that.cannonCount != null) return false;
        if (speedfrequency != null ? !speedfrequency.equals(that.speedfrequency) : that.speedfrequency != null)
            return false;
        if (fishBonus != null ? !fishBonus.equals(that.fishBonus) : that.fishBonus != null) return false;
        if (clientspeedfrequency != null ? !clientspeedfrequency.equals(that.clientspeedfrequency) : that.clientspeedfrequency != null)
            return false;

        return true;
    }

    @Override
    public int hashCode() {
        int result = roomGuid != null ? roomGuid.hashCode() : 0;
        result = 31 * result + (firstTableGuid != null ? firstTableGuid.hashCode() : 0);
        result = 31 * result + (endTableGuid != null ? endTableGuid.hashCode() : 0);
        result = 31 * result + (roomValue != null ? roomValue.hashCode() : 0);
        result = 31 * result + (roomPutScroe != null ? roomPutScroe.hashCode() : 0);
        result = 31 * result + (factor != null ? factor.hashCode() : 0);
        result = 31 * result + (level != null ? level.hashCode() : 0);
        result = 31 * result + (cannonCost != null ? cannonCost.hashCode() : 0);
        result = 31 * result + (cannonCount != null ? cannonCount.hashCode() : 0);
        result = 31 * result + (speedfrequency != null ? speedfrequency.hashCode() : 0);
        result = 31 * result + low;
        result = 31 * result + mid;
        result = 31 * result + high;
        result = 31 * result + (fishBonus != null ? fishBonus.hashCode() : 0);
        result = 31 * result + (clientspeedfrequency != null ? clientspeedfrequency.hashCode() : 0);
        return result;
    }

    @Override
    public String toString() {
        return "RoomInfoEntity{" +
                "roomGuid=" + roomGuid +
                ", firstTableGuid=" + firstTableGuid +
                ", endTableGuid=" + endTableGuid +
                ", roomValue='" + roomValue + '\'' +
                ", roomPutScroe='" + roomPutScroe + '\'' +
                ", factor='" + factor + '\'' +
                ", level='" + level + '\'' +
                ", cannonCost='" + cannonCost + '\'' +
                ", cannonCount='" + cannonCount + '\'' +
                ", speedfrequency='" + speedfrequency + '\'' +
                ", low=" + low +
                ", mid=" + mid +
                ", high=" + high +
                ", fishBonus='" + fishBonus + '\'' +
                ", clientspeedfrequency='" + clientspeedfrequency + '\'' +
                '}';
    }
}
